package hello.app.model.data;

import java.io.Serializable;

public class Comment implements Serializable {
	/**
	 *
	 */
	private static final long serialVersionUID = 2L;

	public static final String TABLE_NAME = "comment";
	public static final String ID = "id";
    public static final String CONTACT_ID = "contact_id";
    public static final String USER_ID = "user_id";
    public static final String USER_EMAIL = "user_email";
    public static final String GOOD = "good";
    public static final String BAD = "bad";
    public static final String TEXT = "text";
    public static final String CREATED_AT = "created_at";
    public static final String UPDATED_AT = "updated_at";

    private Long id = 0L;
    private int contact_id = 0;
    private int user_id = 0;
    private String user_email = "";
    private int good = 0;
    private int bad = 0;
    private String text = "";
    private String created_at = "";
    private String updated_at = "";

    public Comment(Long id, int contact_id, int user_id, String user_email, String text, int good, int bad, String created_at, String updated_at){
    	this(contact_id, user_id, user_email, text, good, bad, created_at, updated_at);
    	this.id = id;
    }

    public Comment(int contact_id, int user_id, String user_email, String text, int good, int bad, String created_at, String updated_at){
    	this.contact_id = contact_id;
    	this.user_id = user_id;
    	this.user_email = user_email != null ? user_email : "";
    	this.text = text != null ? text : "";
    	this.good = good;
    	this.bad = bad;
    	this.created_at = created_at;
    	this.updated_at = updated_at;
    }

	public Long getId() {
		return id;
	}

	public int getContactId() {
		return contact_id;
	}

	public int getUserId() {
		return user_id;
	}

	public String getUserEmail() {
		return user_email;
	}

	public String getText() {
		return text;
	}
	public void setText(String text) {
		this.text = text;
	}
	public String getCreatedAt() {
		return created_at;
	}

	public String getUpdatedAt() {
		return updated_at;
	}

	public int getGood() {
		return good;
	}

	public void setGood(int good) {
		this.good = good;
	}

	public int getBad() {
		return bad;
	}

	public void setBad(int bad) {
		this.bad = bad;
	}

}
